package com.liuzh.deviceinfo.card;

import android.content.Context;
import android.os.Handler;
import android.util.AttributeSet;
import android.view.View.OnClickListener;
import android.widget.LinearLayout;
import android.widget.TextView;
import c.h.a.z.q;
import java.util.concurrent.RejectedExecutionException;

public class SensorAppCard extends LinearLayout {
    public TextView a;
    public TextView b;
    public volatile int c = 0;
    public volatile int d = 0;
    public Runnable e = new a();

    public class a implements Runnable {
        public void run() {
            SensorAppCard sensorAppCard = SensorAppCard.this;
            sensorAppCard.a.setText(String.valueOf(sensorAppCard.c));
            sensorAppCard = SensorAppCard.this;
            sensorAppCard.b.setText(String.valueOf(sensorAppCard.d));
        }
    }

    public SensorAppCard(Context context, AttributeSet attributeSet) {
        super(context, attributeSet);
        setOrientation(0);
        LinearLayout.inflate(getContext(), 2131492935, this);
        setClipToPadding(false);
        setClipChildren(false);
        this.a = (TextView) findViewById(2131296355);
        this.b = (TextView) findViewById(2131296884);
        if (!isInEditMode()) {
            q qVar = new q(this);
            Handler handler = c.h.a.m0.p.a.a;
            try {
                c.h.a.m0.p.a.c.execute(qVar);
            } catch (RejectedExecutionException unused) {
            }
        }
    }

    public void setAppCardClick(OnClickListener onClickListener) {
        findViewById(2131296373).setOnClickListener(onClickListener);
    }

    public void setSensorCardClick(OnClickListener onClickListener) {
        findViewById(2131296890).setOnClickListener(onClickListener);
    }
}
